package com.ontheroad.mysql.activity.service;

import cn.modoumama.service.base.impl.BaseServiceImpl;
import com.ontheroad.activity.model.ActivityTypeModel;
import com.ontheroad.activity.service.ActivityTypeService;
import com.ontheroad.mysql.activity.mapper.ActivityTypeMapper;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * Created by Administrator on 2017/10/27.
 */
@Service
@Transactional
public class ActivityTypeServiceImpl extends BaseServiceImpl<ActivityTypeModel, Integer> implements ActivityTypeService {
    private Logger log = LoggerFactory.getLogger(getClass());

    @Autowired
    private ActivityTypeMapper mapper;

    @Autowired
    public void setMapper(ActivityTypeMapper mapper) {
        setGenericMapper(mapper);
    }

    @Override
    public List<ActivityTypeModel> findByActivityId(Integer activityId) {
        return mapper.findByActivityId(activityId);
    }
}
